//
//  WYMacro.h
//  WYModel
//
//  Created by ios on 2017/3/2.
//  Copyright © 2017年 Wy. All rights reserved.
//

#ifndef WYMacro_h
#define WYMacro_h

#define WS(weakSelf) __weak __typeof(&*self)weakSelf = self

#ifdef DEBUG
#define NSLog(...) NSLog(__VA_ARGS__)
#define WYLog(fmt, ...) NSLog((@"\n[文件名:%s]\n""[函数名:%s]""[行号:%d] \n" fmt), __FILE__, __FUNCTION__, __LINE__, ##__VA_ARGS__);
#else
#define NSLog(...) {}
#define WYLog(...);
#endif

#pragma mark - 宽高
#define kHeight [[UIScreen mainScreen] bounds].size.height
#define kWidth [[UIScreen mainScreen] bounds].size.width

#define SINGLE_LINE_HEIGHT   (1 / [UIScreen mainScreen].scale)

#define kRate(sum) sum * (kWidth/320.0)

#define UserDefaults [NSUserDefaults standardUserDefaults]


#endif /* WYMacro_h */
